This invention relates generally to computer memory, and more specifically to providing wear-leveling and bad block management of limited lifetime memory devices.
Limited lifetime computer storage devices include, but are not limited to, flash memory (e.g., not-and or “NAND” flash memory, and not-or or “NOR” flash memory), and phase change memory (PCM). Device physics dictate a limited number of writes and/or erasures to the memory cells in these limited lifetime memories. For example, NAND flash memory may have on average 105 write/erase cycles per access unit (e.g., a block that contains several kilobytes). Likewise, PCM devices may last for about 108 writes per block. After a block reaches its end of life it may start giving more data errors, and thus, it should be marked as a bad block and avoided for data storage thereafter.
Typically, some memory addresses (referred to as hot-spots) will be busier than others. In general, hot-spot blocks will fail sooner than less busy blocks. Hot spots, if not avoided, can render the entire memory (e.g., one or more memory devices) unusable due to a single bad block. Wear-leveling methods prolong the life of these memories by uniformly distributing writes/erasures across the whole memory such that every block receives an approximately equal number of writes over the lifetime of the whole memory.
Another endurance problem occurs within the unit of access, the block. A block may comprise tens to hundreds of device cells each of which may be storing one bit of data (single-level cell) or a few bits of data (multi-level cell). Each cell within a block may have a different lifetime than others in the same block due to the statistical nature of device manufacturing processes. Thus, cells within a block may fail at different times, rendering the entire block unusable. To help alleviate this problem, error checking and correcting (ECC) techniques are utilized within each memory block. Redundant cells are used in each block to be able to encode data in a variety of manners to recover from cell errors, therefore prolonging the block life. However, there may still be a hot-spot problem within the block. For example, it has been observed that on the average, data at the beginning of a memory page are accessed more often than data towards the end of the page.